package com.ulook.lookplanet.data.source;

import com.ulook.lookplanet.common.AppServer;
import com.ulook.lookplanet.util.net.AsynRequestUtil;
import com.ulook.lookplanet.util.net.RequestParams;
import com.ulook.lookplanet.util.net.ResponseCallback;

/**
 * 描述：
 *
 * @author L1998
 * @data 2021/4/20
 */
public class CommunityDataSource {

    /**
     * 获取小组列表
     */
    public void getCommunityData(ResponseCallback callback){
        AsynRequestUtil.post(AppServer.ROOT_PATH + "/community/getCommunityList", null, null, callback);
    }

    /**
     * 查询话题列表
     */
    public void getTopicsForComuId(String comuId, ResponseCallback callback){
        RequestParams params = new RequestParams();
        params.put("comuId", comuId);
        AsynRequestUtil.post(AppServer.ROOT_PATH + "/community/getTopicsForComuId", params, null, callback);
    }
}
